package com.zhou.blog.controller;

import com.zhou.blog.service.LoginService;
import com.zhou.blog.vo.Result;
import com.zhou.blog.vo.params.LoginParams;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @title:RegisterController
 * @Author Zhou
 * @Date:2022/4/30 13:47
 * @Version 1.0
 */
@RestController
@RequestMapping("api/register")
public class RegisterController {
    @Autowired
    private LoginService loginService;

    @PostMapping
    public Result register(@RequestBody LoginParams loginParams){
        return loginService.register(loginParams);

    }
}
